#ifndef SINGLETON_H_INCLUDED
#define SINGLETON_H_INCLUDED

class Uncopyable
{
protected:
	Uncopyable() {}
private:
	Uncopyable(const Uncopyable&);
	Uncopyable& operator=(const Uncopyable&);
};

template <class T>
class Singleton : public Uncopyable
{
private:
	Singleton() {}

public:
	static T* Instance()
	{
		static T theT;
		return &theT;
	}
};

#endif